home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Die Speccy' 97
/
Die Speccy' 97.iso
/
amiga_system
/
the_aminet
/
util
/
cli
/
reboot.lha
/
reboot.c
< prev
next >
Wrap
C/C++ Source or Header
|
1992-03-06
|
1KB
|
38 lines
/**********************************************************************/
/* MF WBTools reboot.c - perform a cold reboot of the system! */
/* */
/* USAGE: reboot - asks for confirmation (y/n) then reboots */
/* */
/* 13/03/1994 Max Francis */
/**********************************************************************/
#include <exec/exec.h>
#include <stdio.h>
/* Formatted version string for the 2.0 VERSION command */
UBYTE *vers = "\0$VER: MF Reboot v1.0";
main( int argc, char *argv[] )
{
char input[10];
if( argc != 1)
{
printf("MF reboot\nPerform a cold reboot of the system\n");
printf("USAGE: reboot (no arguments)\n");
printf("(equivalent of <CTRL><A><A>)\nAsks for confimation once\n");
}
else
{
printf("Cold Reboot? Confirm (y/n)\n");
scanf("%s", &input);
if( input[0] == 'y' || input[0] == 'Y' )
{
ColdReboot(); /* No turning back now! */
}
else
{
printf("reboot aborted.\n");
}
}
}